%%% File    : chat.erl
%%% Author  :  <whhbest>
%%% Description : 
%%% Created : 26 Feb 2011 by  <>

-module(chat).

-behaviour(application).

%%application callbacks
-export([start/2, stop/1]).

 
%%--------------------------application callbacks
start(normal, _Args) ->
    case chat_sup:start_link() of
	{ok, Pid} ->
	    io:format("start app and master supervisor on node:~p~n", 
		      [node()]),
	    {ok, Pid};
	Err ->
	    io:format("start application error:~p~n", [Err])
    end.

stop(_State) ->
    io:format("stop application.~n", []),
    ok.

%%-------------

    
